package com.aoxon.cargo.service;

import com.aoxon.cargo.bean.GsonBean;
import com.aoxon.cargo.util.HttpUtil;

/**
 * 文件上传的服务
 * @author ZZJ
 *
 */
public class FileUpLoadService extends MyService{
	
	public GsonBean upLoadPicture(String picturePath){
		url = HttpUtil.BASE_URL + "pictureUpload" + suffix;
		
		try{
			String result = HttpUtil.uploadFile(url, picturePath);
			GsonBean gsonBean = gson.fromJson(result, GsonBean.class);
			return gsonBean;
		}catch (Exception e){
			e.printStackTrace();
			return null;
		}
		
	}
}
